<!DOCTYPE html>
<html>

<head>

    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>H+ 后台主题UI框架 - 空白页</title>
    <meta name="keywords" content="">
    <meta name="description" content="">

    <link rel="shortcut icon" href="../favicon.ico">
     <link href="../css/bootstrap.min.css?v=3.3.6" rel="stylesheet">
    <link href="../css/font-awesome.css?v=4.4.0" rel="stylesheet">
     <!-- jqgrid-->
    <link href="../css/animate.css" rel="stylesheet">
    <link href="../css/style.css?v=4.1.0" rel="stylesheet">
    <link href="../css/plugins/sweetalert/sweetalert.css" rel="stylesheet">
    <link href="../css/gyq.css" rel="stylesheet">
    <link rel="stylesheet" href="../css/demo.css" type="text/css">
</head>

<body style="color:#333;padding:3px;overflow-x: auto;">
    <!-- 标题 -->
    <div class="page-heade">
      <h1 class="title_color">批量管理下属客户</h1>
    </div>
    <!-- 标题 -->
     <div>
    <form action="" class="form-inline">
      <table class="row-margin-top tab-content table-bordered table" border="1">
          <tr>
            <td style="min-width: 120px;width: 120px"><label for="" class="form-label">姓名</label></td>
            <td><input type="text" class="form-control" name=""></td>
            <td style="min-width: 120px;width: 120px"><label for="" class="form-label">部门</label></td>
            <td><input type="text" class="form-control" name=""></td>
             <td style="min-width: 120px;width: 120px"><label for="" class="form-label">岗位</label></td>
            <td><input type="text" class="form-control" name=""></td>
        
        </tr>
         <tr>
            <td style="min-width: 120px;width: 120px"><label for="" class="form-label">经销商名称</label></td>
            <td><input type="text" class="form-control" name=""></td>
            <td style="min-width: 120px;width: 120px"><label for="" class="form-label">系统名称</label></td>
            <td><input type="text" class="form-control" name=""></td>
             <td style="min-width: 120px;width: 120px"><label for="" class="form-label">网点名称</label></td>
            <td><input type="text" class="form-control" name=""></td>
        
        </tr>
          <tr>
       <td colspan="6" class="text-center">
           <button class="btn btn-info query" >查询</button>
           <button class="btn btn-info emptyIf" type="button">清空查询条件</button>
           <button class="btn btn-info LendExcel" type="button">导出Excel</button>
            </td>
          </tr>
      </table>
    
      <table class="table row-margin-top table-bordered text-center bud_hei">
                 <tr class="info">
                        <th class="text-center">No.</th>
                        <th class="text-center">姓名</th>
                        <th class="text-center">部门</th>
                        <th class="text-center">岗位</th>
                        <th class="text-center">负责的经销商</th>
                        <th class="text-center">负责的系统</th>
                        <th class="text-center">负责的网点</th>
                        <th class="text-center">操作</th>
                    </tr>
                <tbody>
                    <tr>
                      <td>1</td>
                      <td>Jams Liang</td>
                      <td>总经办</td>
                      <td>总经理</td>
                      <td></td>
                      <td></td>
                      <td></td>
                      <td>
                        <a href="agencymanagment.html">增减经销商</a><br>
                        <a href="systemmanagment.html">增减系统</a><br>
                        <a href="netmanagment.html">增减网点</a><br>
                        <a href="javascript:;" class="allCustom">全部客户交接</a><br>
                      </td>
                    </tr>
                     <tr>
                      <td>2</td>
                      <td>蔡启蒙</td>
                      <td>华中大区</td>
                      <td>华中大区销售代表</td>
                      <td class="text-left agencyList">
                        <p>安阳市海曙品园贸易有限公司</p>
                        <p>安阳市凌浩食品有限公司</p>
                        <p>毕节秦食实业有限公司</p>
                        <p>天门仕丹食品贸易有限公司</p>
                        <p>天门仕丹食品贸易有限公司</p>
                        <span class="spanTotal" style="display: none;" id="agencyTotal">共<span class="spanTotalNum" id="agencyNum">51</span>家经销商</span>
                      </td>
                      <td  class="text-left systemList">
                        <p>广州酒家演示系统</p>
                        <p>合肥家乐福</p>
                        <p>郑州家乐福</p>
                        <span class="spanTotal" style="display: none;" id="systemTotal">共<span class="spanTotalNum" id="systemNum">51</span>家经销商</span>
                      </td>
                      <td  class="text-left netList">
                          <p>合肥家乐福新荟城分店</p>
                          <p>家乐福柏林店</p>
                          <p>家乐福宝龙广场店</p>
                          <p>家乐福长江西路店</p>
                          <p>家乐福长江西路店</p>
                          <p>家乐福长江西路店</p>
                          <p>家乐福长江西路店</p>
                          <p>家乐福长江西路店</p>
                        <span class="spanTotal" style="display: none;" id="netTotal">共<span class="spanTotalNum" id="netNum">51</span>家经销商</span>
                      </td>
                      <td>
                         <a href="agencymanagment.html">增减经销商</a><br>
                        <a href="systemmanagment.html">增减系统</a><br>
                        <a href="netmanagment.html">增减网点</a><br>
                        <a href="javascript:;"  class="allCustom">全部客户交接</a><br>
                      </td>
                    </tr>
                </tbody>
      </table>
       
</form>
    </div>
    <!-- 全局js -->
    <script src="../js/jquery.min.js?v=2.1.4"></script>
    <script src="../js/bootstrap.min.js?v=3.3.6"></script>
    <!-- <script src="js/plugins/metisMenu/jquery.metisMenu.js"></script> -->
    <script src="../js/plugins/slimscroll/jquery.slimscroll.min.js"></script>
     <script src="../js/plugins/layer/layer.min.js"></script>
       <script src="../js/plugins/sweetalert/sweetalert.min.js"></script>
    <script src="../js/common.js"></script>
    <script>
      $(document).ready(function(){
         var $agencyListP=$(".agencyList p");
         var $systemListP=$(".systemList p");
         var $netListP=$(".netList p");
         var $agencyTotal=$("#agencyTotal");
         var $systemTotal=$("#systemTotal");
         var $netTotal=$("#netTotal");
          showInfo($agencyListP,$agencyTotal);
          showInfo($systemListP,$systemTotal);
          showInfo($netListP,$netTotal);


      /*全部客户交接*/
      $(".allCustom").click(function(){
              swal({ 
              title: "", 
              text: "您确定把批量管理下属客户所有负责的客户(经销商、系统、网点)都交换给另外一个人吗？", 
              type: "warning",
              showCancelButton: true, 
              confirmButtonColor: "#DD6B55",
              confirmButtonText: "确定", 
              cancelButtonText: "取消",
              closeOnConfirm: true, 
              closeOnCancel: true
            },
          function(){
            
           });
         })
      })
      function showInfo(item,totalnum){
           for(var i=0;i<item.length;i++){
               if(i>3){
               // console.log($agencyListP[i])
               item[i].style.display ="none";
                totalnum.show();
               totalnum.find(".spanTotalNum").html(item.length);
               }
           }
        }
    </script>
</body>

</html>
